package com.project.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.time.LocalDate;
import java.util.Date;

/**
 * 采购单实体
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("t_order")
public class Order implements Serializable {

    private static final long serialVersionUID = 1L;

    /** 采购单编号*/
    @TableId(value = "pk_orderId", type = IdType.AUTO)
    private Integer OrderId;

    /** 采购时间*/
    @TableField("o_inDate")
//    private LocalDate inDate = LocalDate.now();
    private  String inDate;

    /** 供应商ID*/
    @TableField("fk_factoryId")
    private Integer factoryId;

    @TableField(exist = false)
    private Factory factory;
    /** 采购人编号*/
    @TableField("fk_userId")
    private Integer userId;

       /** 采购人对象*/
    @TableField(exist = false)
    private User user;

    /** 商品对象*/
    @TableField(exist = false)
    private  Product product;


}
